import request from '@/utils/request'

// 从接口文档中粘贴过来
// 删除BaseTrademark   DELETE  /admin/product/baseTrademark/remove/{id}
// 新增BaseTrademark   POST    /admin/product/baseTrademark/save
// 修改BaseTrademark   PUT     /admin/product/baseTrademark/update
// 分页列表            GET     /admin/product/baseTrademark/{page}/{limit}

export interface TrademarkModel {
  id: number,
  tmName: string,
  logoUrl: string
}

export type TrademarkList = TrademarkModel[]


export interface TrademarkPageModel {
  current: number,
  pages: number,
  records: TrademarkList, 
  searchCount: boolean,
  size: number,
  total: number
}

export default {
  // 查询分页
  getPage(page: number, limit: number) {
    return request.get<any, TrademarkPageModel>(`/admin/product/baseTrademark/${ page }/${ limit }`)
  },
}